var task_id=GetQueryString('task_id');
var modifyData;
var qxlist ;
var dhbm = dhbm_cjlr;
var processDefKey = "minbocaiji";
var readflag = false;
$(document).ready(function(){
	var result = ajaxResult("get",false,"/cnmuseum/cj/getdetail",{"task_id":task_id});
	if(result.status=='OK'){
		modifyData=result.data;
	}
	getUserInfo();
	qxlist = UserInfo.qxlist;
	loadAddHtml();
});
//数据录入的保存
function save(ele){ 
	$("a[name=btn]").button('loading').delay(1000).queue(function() {
		$("a[name=btn]").button('reset');
		$("a[name=btn]").dequeue(); 
	});
	$(ele).button('loading').delay(1000).queue(function() {
		$(ele).button('reset');
		$(ele).dequeue(); 
		var params=$('#addForm').serializeObject();
		var result=ajaxResult('POST',false,'/cnmuseum/cj/save',params);
		if(result.status=='OK'){
			alertFunc('保存成功',function(){
				window.location.href='zjlr.html';
			});
		}
	});
}
//数据录入的提交
function submit(ele){
	$("a[name=btn]").button('loading').delay(1000).queue(function() {
		$("a[name=btn]").button('reset');
		$("a[name=btn]").dequeue(); 
	});
	$(ele).button('loading').delay(1000).queue(function() {
		$(ele).button('reset');
		$(ele).dequeue(); 
		var params=$('#addForm').serializeObject();
		params.next='cj';
		var result=ajaxResult('POST',false,'/cnmuseum/cj/submit',params);
		if(result.status=='OK'){
			alertFunc('提交成功',function(){
				window.location.href='zjlr.html';
			});
		}
	});
}
